package tr.edu.metu.is.mega.client.service;

import java.util.List;

import tr.edu.metu.is.mega.common.dto.AnnouncementDTO;
import tr.edu.metu.is.mega.common.dto.CourseDTO;

import com.google.gwt.user.client.rpc.AsyncCallback;

/**
 * Async interface for {@link GwtAnnouncementService}
 */
public interface GwtAnnouncementServiceAsync {

    /**
     * @see GwtAnnouncementService#createAnnouncement(AnnouncementDTO)
     */
    void createAnnouncement(AnnouncementDTO announcement, AsyncCallback<AnnouncementDTO> callback);

    /**
     * @see GwtAnnouncementService#updateAnnouncement(AnnouncementDTO)
     */
    void updateAnnouncement(AnnouncementDTO announcement, AsyncCallback<AnnouncementDTO> callback);

    /**
     * @see GwtAnnouncementService#deleteAnnouncement(AnnouncementDTO)
     */
    void deleteAnnouncement(AnnouncementDTO announcement, AsyncCallback<Void> callback);

    /**
     * @see GwtAnnouncementService#getAnnouncements(CourseDTO)
     */
    void getAnnouncements(CourseDTO course, AsyncCallback<List<AnnouncementDTO>> callback);

}
